Skip to content

Fix unreadable What's New titles/links when OS and PowerToys themes differ - #48910

Merged
niels9001 merged 1 commit into
mainfrom
niels9001-whatsnew-darkmode-titles
Jun 29, 2026
Merged

Fix unreadable What's New titles/links when OS and PowerToys themes differ#48910
niels9001 merged 1 commit into
mainfrom
niels9001-whatsnew-darkmode-titles

Conversation

@niels9001

@niels9001 niels9001 commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Summary of the Pull Request

When the OS theme differs from the PowerToys theme (e.g. OS in Light, PowerToys set to Dark), the What's New / release-notes (Scoobe) page renders heading titles and hyperlinks with brushes pinned to the wrong theme, making them unreadable. The system caption buttons (min/max/close) are also not tinted to match the window theme.

The release-notes page uses the CommunityToolkit MarkdownTextBlock, which captures its heading and link brushes from Application.Current.Resources when its theme config is created. Those resolve against the OS (application) theme rather than the window's selected element theme, so headings/links break whenever the two themes differ.

PR Checklist

Detailed Description of the Pull Request / Additional comments

These are deliberately local workarounds until the upstream control resolves brushes against the element theme via CommunityToolkit/Labs-Windows#785. Comments + TODOs in the code point at that PR so the workaround can be removed once it ships.

ScoobeReleaseNotesPage

  • Pin the MarkdownTextBlock.RequestedTheme to the selected app theme and reassign the H1H6 heading brushes and the link brush (resolved for that theme) before the markdown is rendered. The themed brushes are read from the control's own Foreground (TextFillColorPrimaryBrush) and a hidden LinkBrushProvider carrier element (AccentTextFillColorPrimaryBrush).
  • Re-run the workaround and force a re-render on runtime theme changes (subscribe to the page's ActualThemeChanged), so titles/links stay readable when the user switches Light/Dark while the window is open.

TitleBarHelper (new) + ScoobeWindow

  • Add a small shared TitleBarHelper.ApplySystemThemeToCaptionButtons(window, theme) (port of the WinUI Gallery helper + PowerToys conventions) and drive the Scoobe window's caption-button colors from the content's actual theme, updating on ActualThemeChanged. ScoobeWindow uses the built-in WinUI TitleBar, which — unlike the custom PowerToys TitleBar control used by the other Settings windows — does not tint the system caption buttons to the app theme.

Validation Steps Performed

  • OS Light + PowerToys Dark: opened What's New → headings, hyperlinks, body text and caption buttons all render readable/dark-themed (previously black/unreadable titles). Confirmed working.
  • Switched OS Light → Dark while the Scoobe window was open → markdown content and caption buttons update live.
  • OS Dark: content pane, tables and titles render with the dark theme (addresses the "light pane in a dark window" report).
Screenshot 2026-06-26 130638

OS is in Light Mode, while the app settings are set to Dark mode

…iffer

The release-notes (Scoobe) page uses the CommunityToolkit MarkdownTextBlock, which captures its heading and link brushes from Application.Current.Resources, resolving them against the OS (application) theme instead of the window's selected theme. When the OS theme differs from the PowerToys theme, headings and hyperlinks render with unreadable colors, and the system caption buttons aren't tinted to match.

Workarounds (until CommunityToolkit/Labs-Windows#785 lands upstream):

- Pin the MarkdownTextBlock RequestedTheme and reassign H1-H6 + link brushes resolved for the selected theme before rendering, and re-apply on runtime theme changes.

- Add a shared TitleBarHelper to tint the system caption buttons to the window's actual theme (ScoobeWindow uses the built-in WinUI TitleBar, which doesn't do this).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions github-actions Bot added the Area-Localization issues regarding to Localization the application label Jun 26, 2026
@niels9001 niels9001 added Product-Settings The standalone PowerToys Settings application and removed Area-Localization issues regarding to Localization the application labels Jun 26, 2026
@niels9001
niels9001 requested a review from crutkas June 27, 2026 09:38
@niels9001

Copy link
Copy Markdown
Collaborator Author

@crutkas you were running into this issue too, right?

@jiripolasek jiripolasek left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

I was able to reproduce the issue without the fix and verify that it no longer occurs with this change applied. HC themes also work fine.

Image

@niels9001
niels9001 merged commit a46a443 into main Jun 29, 2026
8 checks passed
@niels9001
niels9001 deleted the niels9001-whatsnew-darkmode-titles branch June 29, 2026 18:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Product-Settings The standalone PowerToys Settings application

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"What's new" content view doesn't inherit dark app theme "whats new" panel dark text in dark mode

2 participants